<%--
  Created by IntelliJ IDEA.
  User: 几何
  Date: 2022/4/22
  Time: 21:34
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<script src="https://code.jquery.com/jquery-3.3.1.min.js"></script>
<html>
<head>
    <title>Title</title>
</head>
<body>
<c:forEach var="item" items="${comment}">
    <c:if test="${item.commentId!=0}">
        评论：
       <c:if test="${item.commentusers.userId!=null}">
           回复：<a href="${pageContext.request.contextPath}/userfunction/queryothersdata?othersName=${item.commentusers.userName}">
           ${item.commentusers.petName}</a>
       </c:if>
        ${item.commentValue} &nbsp; 评论时间：${item.commentDate}<br/>
        所属帖：${item.posts.postTitle}<br/>
    </c:if>
    <c:if test="${item.replyId!=0}">
        回复：
        ${item.replyValue} &nbsp; 回复时间：${item.replyDate}<br/>
        所属帖：${item.postsList.postTitle}<br/>
    </c:if><br/>
</c:forEach>

</body>
</html>
